import request from '@/utils/request.js'

// 获取小区列表
export const getCommunityListApi = () => request.get('/community')
// 获取小区栋数列表
export const getBuildingListApi = (code) => request.get('/house/building?community_code=' + code)
// 获取所属房产
export const getHouseListApi = (code) => request.get('/house/index?building_code=' + code)
// 获取所属成员
export const getMemberListApi = (code) => request.get('/owners/member?house_code=' + code)
// 获取列表
export const getListApi = (params) => request.get('/owners/member', { params })
// 删除
export const delListApi = (id) => request.delete('/owners/member/' + id)
// 添加
export const addListApi = (data) => request.post('/owners/member', data)
// 获取人员详情
export const getListInfoApi = (id) => request.get('/owners/member/' + id)
// 修改
export const editListApi = (data) => request.put('/owners/member/' + data.id, data)